package org.pfc.porlapatilla.repositories;

import org.pfc.porlapatilla.model.Category;
import org.springframework.data.mongodb.repository.MongoRepository;

/**
 * This Repository provides data access to CategoryService.
 * 
 * @author jorgepolobermudez
 * 
 */
public interface CategoryRepository extends MongoRepository<Category, String> {

    /**
     * Find a category by name.
     * 
     * @param name
     *            The category name.
     * @return The found category.
     */
    Category findByName(String name);

}
